package com.qinhao.loveCrowdFunding.mapper;

import com.qinhao.loveCrowdFunding.pojo.ApproveReviewEntity;
import com.qinhao.loveCrowdFunding.pojo.BeReportedReasonBO;
import com.qinhao.loveCrowdFunding.pojo.LoveCrowdSimpleInformation;
import com.qinhao.loveCrowdFunding.pojo.ReportUserIdBO;
import com.qinhao.loveCrowdFunding.req.ApproveReportRequest;
import com.qinhao.loveCrowdFunding.req.ApproveReviewRequest;
import com.qinhao.loveCrowdFunding.req.RejectReportRequest;
import com.qinhao.loveCrowdFunding.req.RejectReviewRequest;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

@Mapper
public interface AdminMapper {
    // 获取未被审核的众筹信息
    List<LoveCrowdSimpleInformation> getUnapproved();
    // 获取被举报的众筹信息
    List<LoveCrowdSimpleInformation> getReported();
    // 获取所有众筹信息
    List<LoveCrowdSimpleInformation> getAll();
    // 修改众筹简单信息的状态，从0到3
    void rejectReview(RejectReviewRequest rejectReviewRequest);
    // 修改众筹简单信息的状态，从0到1
    void approveReview(ApproveReviewRequest approveReviewRequest);
    // 根据simpleInformation的id修改截止日期
    void setEndDateById(ApproveReviewEntity approveReviewEntity);
    // 更改状态为1
    void convertStatusToPublishBySimpleInformationId(RejectReportRequest rejectReportRequest);
    // 获取举报人id
    List<ReportUserIdBO> getReportUserId(RejectReportRequest rejectReportRequest);
    // 删除相关的举报内容
    void deleteReportContentBySimpleInformationId(RejectReportRequest rejectReportRequest);
    // 获取被举报的众筹原因
    List<BeReportedReasonBO> getBeReportedReasonBySimpleInformationId(LoveCrowdSimpleInformation loveCrowdSimpleInformation);
    // 更改状态为5
    void convertStatusToAbnormalEndBySimpleInformationId(ApproveReportRequest approveReportRequest);
}
